#!/usr/bin/env python3
# -*- coding: utf-8 -*-

Import('env')
env = env.Clone()

import glob

# 查找所有 .cpp 和 .cc 文件
cpp_sources = env.GlobSources('src/*.cpp')
cpp_sources += env.GlobSources('src/*.cc')
cc_sources = []
sources = cpp_sources + cc_sources

env.AddStaticLibrary(
    name='ipc_client',
    sources=sources,
    include_paths=['inc'],
    export_include_paths=['inc'],
    cxxflags=['-g', '-Wall'],
    static_libs=['ipc_framework', 'ipc_services', 'ipc-client-service-proto', 'protobuf']  # 依赖ipc-framework和ipc-services模块
)

env.AddProtoLibrary(
    name="ipc-client-service-proto",
    proto_files=[
        "src/IpcSimService.proto"
    ],
    proto_type="lite",  # 支持 full/lite/min
)